import Vue from 'vue'
import App from './App.vue'
import router from './router'
import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
import QrcodeVue from 'qrcode.vue'

import cookie from 'vue-cookie'
Vue.prototype.$cookie = cookie;

import axios from 'axios'
// axios.defaults.baseURL = 'http://127.0.0.1:3000';
axios.defaults.baseURL = 'http://agent.zhongkebang.com';
// axios请求拦截器（请求头中添加token）
axios.interceptors.request.use(config => {
  config.headers.Authorization = cookie.get('token')
  return config
})
Vue.prototype.$http = axios



Vue.use(ElementUI);
Vue.config.productionTip = false

new Vue({
  router,
  render: h => h(App)
}).$mount('#app')
